<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="MvcContrib.FluentHtml.ModelViewPage<Universum.Views.Blogs.BlogShowAllViewModel>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Universum - Show all users with blogs
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
	<h2>
		All users with blogs</h2>
	<table>
		<%
		
			var count = Model.UsersWithBlogs.Count;
			for (int index = 0; index < Model.UsersWithBlogs.Count; index += 4)
			{				
			
		%>
		<tr>			
				<% 
				for(int column = 0; column < 6; column ++){
					if (index + column < count)
					{
						Writer.Write("<td>&nbsp;");
						Html.BeginLinkWithUsername<BlogsController>(it => it.Show(0), Model.UsersWithBlogs[index + column]); %>
				<%=  Model.UsersWithBlogs[index + column]%>
				<% Html.EndLink();
	   Writer.Write("</td>");
					}
			} %>
			</td>
			
		</tr>
		<%
			}    	
		%>
	</table>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ScriptPlaceHolder" runat="server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="Breadcrumbs" runat="server">
<%= Html.Breadcrumb().Home().Append<BlogsController>( it=>it.Index(), "Your blog").AppendText("Show all users with blogs").End() %>
</asp:Content>
